<template>
	<div class="app-container">
			<el-table :data="list" border style="width: 100%">
				<el-table-column prop="SupplierId" label="供货商id" align="center">
				</el-table-column>
				<el-table-column prop="SupplierName" label="供货商名称" align="center">
				</el-table-column>
				<el-table-column prop="LastTime" label="上次登录时间" align="center" >  <!--:formatter="formatDate"-->
				</el-table-column>
				<el-table-column prop="LastIP" label="上次登录时间" align="center">
				</el-table-column>
			</el-table>
			<el-pagination background layout=" prev, pager, next, jumper" @current-change="handleCurrentChange" :page-size="pageSize" :total="total" style="float:right;margin-top: 10px;">
			</el-pagination>
	</div>
</template>

<script>
	export default {
		data() {
			return {
				list: [{
					SupplierId:'31',
					SupplierName:'上海龙瀚',
					LastTime:"2019-03-23",
					LastIP:"198.22.13"
				},{
					SupplierId:'31',
					SupplierName:'上海龙瀚',
					LastTime:"2019-03-23",
					LastIP:"198.22.13"
				}],
				page: 1,
				pageSize: 20,
				total: 10000000000,
			};
		},
		methods: {
				formatDate: function(row) {
				var date = new Date(row.Ins);
				var yy = date.getFullYear();
				if(yy < 1900) yy = yy + 1900;
				var MM = date.getMonth() + 1;
				if(MM < 10) MM = '0' + MM;
				var dd = date.getDate();
				if(dd < 10) dd = '0' + dd;
				var hh = date.getHours();
				if(hh < 10) hh = '0' + hh;
				var mm = date.getMinutes();
				if(mm < 10) mm = '0' + mm;
				var ss = date.getSeconds();
				if(ss < 10) ss = '0' + ss;
				return yy + "年" + MM + "月" + dd + "日" + " " + hh + ":" + mm + ":" + ss;
			},

			handleCurrentChange(val) {
				this.page = val;
			},
		},

	};
</script>

<style>

</style>